package com.atguigu.gulimall.product.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;

import java.io.Serializable;

import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 品牌分类关联
 * 
 * @author GuanMing.Zhu
 * @email xiaoming.080797@gmail.com
 * @date 2020-10-20 20:52:23
 */
@Builder
@Data
@TableName("pms_category_brand_relation")
@NoArgsConstructor
@AllArgsConstructor
public class CategoryBrandRelationEntity implements Serializable {
	private static final long serialVersionUID = 1L;

	/**
	 * 
	 */
	@TableId
	private Long id;
	/**
	 * 品牌id
	 */
	private Long brandId;
	/**
	 * 分类id
	 */
	private Long catelogId;
	/**
	 * 
	 */
	private String brandName;
	/**
	 * 
	 */
	private String catelogName;

	public CategoryBrandRelationEntity(Long brandId, String name) {
		this.brandId = brandId;
		this.brandName = name;
	}

	public CategoryBrandRelationEntity initNameInfo(String brandName, String categoryName) {
		this.brandName = brandName;
		this.catelogName = categoryName;
		return this;
	}
}
